cmake_minimum_required(VERSION 3.23)
project(vulkan_01)

set(CMAKE_CXX_STANDARD 17)

if(MSVC)
    set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /utf-8")
endif()

# 一些顶级目录
set(IN_HOME ON)
if(IN_HOME)
    set(MY_CPP_LIBS_PATH "E:/cpp/libs")
    set(MY_VULKAN_PATH "F:/apps/vulkan")
else()
    set(MY_CPP_LIBS_PATH "G:/ai_cpp/cpp_libs")
    set(MY_VULKAN_PATH "G:/apps/vulkan")
endif(IN_HOME)


##############################
# 头文件
# glm
include_directories("${MY_VULKAN_PATH}/Include")

# glfw3 3.8
include_directories("${MY_CPP_LIBS_PATH}/glfw-3.3.8.bin.WIN64/include")


add_executable(vulkan_01 hello_triangle.cpp)


# 链接静态库
target_link_libraries(vulkan_01
        "${MY_CPP_LIBS_PATH}/glfw-3.3.8.bin.WIN64/lib-vc2017/glfw3.lib"
        "${MY_VULKAN_PATH}/Lib/vulkan-1.lib"
        )